package com.gcsoftware.utils;

/**
 * Created by qs on 2018/3/22.
 */
public class SysConst {
    public static final String DICT_GRP_USER_STATUS = "GRP_USER_STATUS";
    public static final String DICT_GRP_PWD_STATUS = "GRP_PWD_STATUS";
    public static final String DICT_GRP_USER_OPERATE_STATUS = "GRP_USER_OPERATE_STATUS";
    public static final String DICT_GRP_APP_STATUS = "GRP_APP_STATUS";
    public static final String DICT_GRP_APP_TYPES = "GRP_APP_TYPES";
    public static final String DICT_GRP_INTERF_STATUS = "GRP_INTERF_STATUS";
    public static final String DICT_GRP_IPARAMS_TYPE = "GRP_IPARAMS_TYPE";
    public static final String DICT_GRP_IPARAMS_DATATYPE = "GRP_IPARAMS_DATATYPE";
    public static final String DICT_GRP_COMPANY_STATUS = "GRP_COMPANY_STATUS";
    public static final String DICT_GRP_VERIFY_TYPES = "GRP_VERIFY_TYPES";
    public static final String DICT_GRP_VERIFY_STATUS = "GRP_VERIFY_STATUS";

    /**
     * 角色类型
     */
    public static final String SYS_ROLE_TYPE_ADMIN = "1";
    public static final String SYS_ROLE_TYPE_COMPANY = "0";

    /*
     * 用户状态 注册
     */
    public static final String DICT_USER_STATUS_REGISTER = "USER_STATUS_REGISTER";
    /*
     * 用户状态 正常
     */
    public static final String DICT_USER_STATUS_NORMAL = "USER_STATUS_NORMAL";
    /*
    用户状态 锁定
     */
    public static final String DICT_USER_STATUS_LOCKED = "USER_STATUS_LOCKED";
    /*
    用户状态 禁用
     */
    public static final String DICT_USER_STATUS_UNABLE = "USER_STATUS_UNABLE";

    public static final String DICT_PWD_STATUS_NORMAL = "PWD_STATUS_NORMAL";
    public static final String DICT_PWD_STATUS_UNABLE = "PWD_STATUS_UNABLE";


    /**
     * 应用状态
     */
    public static final String DICT_APP_STATUS_INIT = "APP_STATUS_INIT";
    public static final String DICT_APP_STATUS_REG_UNAUDIT ="APP_STATUS_REG_UNAUDIT";  //待审核
    public static final String DICT_APP_STATUS_PUBLISH = "APP_STATUS_PUBLISH";
    public static final String DICT_APP_STATUS_OFFLINE = "APP_STATUS_OFFLINE";


    /**
     * 接口状态
     */
    public static final String DICT_INTERF_STATUS_INIT = "INTERF_STATUS_INIT";
    public static final String DICT_INTERF_STATUS_UNAUDIT ="INTERF_STATUS_UNAUDIT";  //待审核
    public static final String DICT_INTERF_STATUS_PUBLISH = "INTERF_STATUS_PUBLISH";
    public static final String DICT_INTERF_STATUS_OFFLINE = "INTERF_STATUS_OFFLINE";

    public static final String DICT_OPERATE_STATUS_SUCCESS = "OPERATE_STATUS_SUCCESS";
    public static final String DICT_OPERATE_STATUS_FAILED = "OPERATE_STATUS_FAILED";

    /**
     * 应用类型 APP_TYPE_PROVIDER服务提供方
     */
    public static final String DICT_APP_TYPE_PROVIDER = "APP_TYPE_PROVIDER";
    public static final String DICT_APP_TYPE_CALLER = "APP_TYPE_CALLER";

    /**
     * 厂家状态
     */
    public static final String DICT_COMPANY_STATUS_REGISTER = "COMPANY_STATUS_INIT";
    public static final String DICT_COMPANY_STATUS_NORMAL = "COMPANY_STATUS_NORMAL";

    public static final  String DFT_ROLE_COMPANY = "DFT_ROLE_COMPANY_000000000000001";

    /**
     * 审核状态
     */
    public static final String VERIFY_STATUS_UNVERIFY="VERIFY_STATUS_UNVERIFY"; //待审核
    public static final String VERIFY_STATUS_APPROVED="VERIFY_STATUS_APPROVED"; //审核通过
    public static final String VERIFY_STATUS_NOT_APPROVED="VERIFY_STATUS_NOT_APPROVED"; //审核不通过
    public static final String VERIFY_STATUS_UNABLE="VERIFY_STATUS_UNABLE"; //审核不可用

    /**
     * 审核类型
     */
    public static final String VERIFY_TYPE_USER_REGISTER="VERIFY_TYPE_USER_REGISTER"; //用户注册
    public static final String VERIFY_TYPE_COMPANY_REGISTER="VERIFY_TYPE_COMPANY_REGISTER"; //厂家注册
    public static final String VERIFY_TYPE_APP_REGISTER="VERIFY_TYPE_APP_REGISTER"; //应用注册
    public static final String VERIFY_TYPE_APP_CHANGED="VERIFY_TYPE_APP_CHANGED"; //应用变更
    public static final String VERIFY_TYPE_APP_OFFLINE="VERIFY_TYPE_APP_OFFLINE"; //应用下线
    public static final String VERIFY_TYPE_INTERF_REGISTER="VERIFY_TYPE_INTERF_REGISTER"; //接口注册
    public static final String VERIFY_TYPE_INTERF_CHANGED="VERIFY_TYPE_INTERF_CHANGED"; //接口变更
    public static final String VERIFY_TYPE_INTERF_OFFLINE="VERIFY_TYPE_INTERF_OFFLINE"; //接口下线


    public static final String CHANGE_TYPE_APP_INFO = "CHANGE_TYPE_APP_INFO";
    public static final String CHANGE_TYPE_APP_IP_ADD = "CHANGE_TYPE_APP_IP_ADD";
    public static final String CHANGE_TYPE_APP_IP_DEL = "CHANGE_TYPE_APP_IP_DEL";

    public static final String CHANGE_TYPE_INTERF_INFO = "CHANGE_TYPE_INTERF_INFO";
    public static final String CHANGE_TYPE_INTERF_SERVICE = "CHANGE_TYPE_INTERF_SERVICE";
    public static final String CHANGE_TYPE_INTERF_IPARAMS = "CHANGE_TYPE_INTERF_IPARAMS";

    public static String getDescriptionByVerifyType(String verify_type) {
        String des = "";
        switch (verify_type) {
            case VERIFY_TYPE_USER_REGISTER:
                des = "用户注册";
                break;
            case VERIFY_TYPE_COMPANY_REGISTER:
                des = "厂家注册";
                break;
            case VERIFY_TYPE_APP_REGISTER:
                des = "应用注册";
                break;
            case VERIFY_TYPE_APP_CHANGED:
                des = "应用变更";
                break;
            case VERIFY_TYPE_APP_OFFLINE:
                des = "应用下线";
                break;
            case VERIFY_TYPE_INTERF_REGISTER:
                des = "接口注册";
                break;
            case VERIFY_TYPE_INTERF_CHANGED:
                des = "接口变更";
                break;
            case VERIFY_TYPE_INTERF_OFFLINE:
                des = "接口下线";
                break;
        }
        return des;
    }


}
